<template>
  <div class="collapse-box">
    <slot v-if="show"></slot>
    <div class="box-button" @click="show=!show" :style="{right:show?'-20px':'-45px'}">
      <el-button icon="el-icon-arrow-right" circle type="primary" v-if="!show"/>
      <el-button icon="el-icon-arrow-left" circle type="primary" v-else/>
    </div>
  </div>
</template>

<script>
export default {
  data() {
    return {
      show:true
    }
  },
  methods: {}
}
</script>
<style lang="scss" scoped>
.collapse-box{
  position: relative;
  min-height: 100vh;
  .box-button{
    position: absolute;
    bottom:40vh;
    z-index: 2;
  }
}
</style>
